package com.mbc.web.common.client.controller;

import com.google.gwt.user.client.rpc.AsyncCallback;
import com.mbc.common.entities.Role;
import com.mbc.common.entities.User;
import com.mbc.common.param.CriteriaParams;
import com.mbc.web.common.shared.dto.BranchChangeLogDataListDTO;
import com.mbc.web.common.shared.dto.LevelAppItemListDTO;
import com.mbc.web.common.shared.dto.RoleDataListDTO;
import com.mbc.web.common.shared.dto.RoleListDTO;
import com.mbc.web.common.shared.dto.UserDataListDTO;
import com.mbc.web.common.shared.dto.UserViewLoadDTO;

public interface WebAccessControllerAsync {
	//User
	void createUser(User user, AsyncCallback<Integer> callback) ;
	void updateUser(User user, AsyncCallback<Integer> callback);
	void deleteUser(long userID, AsyncCallback<Integer> callback);
	void getUserList(CriteriaParams cri, AsyncCallback<UserDataListDTO> callback);
	void getUser(long userId, AsyncCallback<User> callback);
	void findUserByLoginId(String loginId, AsyncCallback<User> callback);
	void getUserViewLoadData(AsyncCallback<UserViewLoadDTO> callback);
	void resetLoginPassword(String oldPassword, String newPassword, AsyncCallback<Integer> callback);
	void changeUserBranch(String loginId, long branchId, AsyncCallback<Integer> callback);
	void findUserBranchChangeLogs(CriteriaParams cri, AsyncCallback<BranchChangeLogDataListDTO> callback);
	//End User
	
	//Role
	void createRole(Role role, AsyncCallback<Integer> callback);
	void updateRole(Role role, AsyncCallback<Integer> callback);
	void deleteRole(long roleId, AsyncCallback<Integer> callback);
	void findRole(long roleId, AsyncCallback<Role> callback);
	void getAllRole(AsyncCallback<RoleListDTO> callback);
	void getRoleList(CriteriaParams cri,AsyncCallback<RoleDataListDTO> callback);
	void getLevelAppItemByRoleId(long roleId, AsyncCallback<LevelAppItemListDTO> callback);
	//End Role
}
